package graphics 
{
	import graphics.IGraphic;
	/**
	 * ...
	 * @author Gareth Williams
	 */
	public final class GraphicsFactory
	{
		public static const RED_SQUARE:String = "red square graphic";
		public static const BLUE_SQUARE:String = "blue square graphic";
		public static const GREEN_CIRCLE:String = "green circle graphic";
		public static function createGraphic(type:String, width:Number, height:Number):IGraphic
		{
			var product:IGraphic = null;
			switch(type)
			{
				case RED_SQUARE: //good guy
					product = new Square(0xFF0000, width, height);
				break
				case BLUE_SQUARE: //bad guy
				default:
					product = new Square(0x0000FF, width, height);
				break
				case GREEN_CIRCLE: //bullet
					product = new Circle(0x00FF00, width);
				break
			}
			return product;
		}
	}
}